<template>
  <div class="about">
    <h1>This is an about page</h1>
    <button @click="collectBtn">收藏</button>
  </div>
</template>

<script lang="ts">
import { defineComponent } from 'vue';
import { collects } from "@/utils/api";
export default defineComponent({
  methods: {
    collectBtn() {
      let id = 6;
      collects(id).then((res) => {
        console.log(res);

      }).catch(err => {
        console.log(err);

      })
    }
  }

})
</script>

<style lang="scss" scoped>

</style>